﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UtilLib;

namespace ConfClient
{
    //全局配置
    public class GlobalConfigExt
    {
        public int GlobalId;
        public ConfigGlobal SettBase;
        public string Value;
        public bool ValueBool;
        public int ValueInt;
        public long ValueLong;
        public float ValueFloat;
        public List<string> ValueListString;
        public List<int> ValueListInt;
        public List<float> ValueListfloat;
        public List<List<int>> ValueListListInt;
        public GlobalConfigExt(ConfigGlobal v)
        {
            GlobalId = v.GlobalId;
            SettBase = v;
            Value = v.Value;
            ValueBool = Value.ToBool();
            ValueInt = Value.ToInt();
            ValueLong = Value.ToLong();
            ValueFloat = Value.ToFloat();
            ValueListString = Value.ToListString(Conf.ConfListSeparator);
            ValueListInt = Value.ToListInt(Conf.ConfListSeparator);
            ValueListfloat = Value.ToListFloat(Conf.ConfListSeparator);
            ValueListListInt = Value.ToListListInt(Conf.ConfDictionarySeparator1, Conf.ConfDictionarySeparator2);
        }
    }


}